package com.lkd.mapper;

import com.lkd.dto.UserDto;
import com.lkd.entity.User;
import com.lkd.vo.UserVo;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface UserMapper {

    @Select("select * from tb_user where login_name=#{loginName}")
    User getByLoginName(String loginName);

    Boolean save(User user);

    List<UserVo> findList(UserDto userDto);

    Boolean update(User user);

    @Delete("delete from tb_user where id = #{id}")
    Boolean deleteById(Integer id);
}
